/*
 *      Fischer Chess Club
 *      Copyright (c) 2010 Ryan Chiu
 *      All rights reserved.
 *      
 *      This program is free software: you can redistribute it and/or modify
 *      it under the terms of the GNU General Public License as published by
 *      the Free Software Foundation, either version 3 of the License, or
 *      (at your option) any later version.
 *      
 *      This program is distributed in the hope that it will be useful,
 *      but WITHOUT ANY WARRANTY; without even the implied warranty of
 *      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *      GNU General Public License for more details.
 *      
 *      You should have received a copy of the GNU General Public License
 *      along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

package fischer;

import java.util.HashMap;

public class List {
    public static HashMap<Integer, String> userlevels = new HashMap<Integer, String>();

    // List type keys
    public static final int PERSONAL = 1;
    public static final int PUBLIC = 2;
    
    // Server-wide/public lists.
    public static String[] admins      = {};
    public static String[] tms         = {};
    public static String[] srs         = {};
    public static String[] vendors     = {};
    public static String[] gms         = {};
    public static String[] ims         = {};
    public static String[] fms         = {};
    public static String[] wgms        = {};
    public static String[] wims        = {};
    public static String[] wfms        = {};
    public static String[] tds         = {};
    public static String[] abusers     = {};
    public static String[] banned      = {};
    public static String[] ch1muzzle   = {};
    public static String[] ch50muzzle  = {};
    public static String[] shoutmuzzle = {};

    // List tags
    public static final String admin_tag  = "(*)";
    public static final String tm_tag     = "(TM)";
    public static final String sr_tag     = "(SR)";
    public static final String vendor_tag = "(V)";
    public static final String gm_tag     = "(GM)";
    public static final String im_tag     = "(IM)";
    public static final String fm_tag     = "(FM)";
    public static final String wgm_tag    = "(WGM)";
    public static final String wim_tag    = "(WIM)";
    public static final String wfm_tag    = "(WFM)";
    public static final String td_tag     = "(TD)";

    public static final String headadmin = "Ryan";
    
    public List() {
        userlevels.put(-50, "Banned");
        userlevels.put(-30, "Abuser");
        userlevels.put(-10, "Guest");
        userlevels.put(1  , "User");
        userlevels.put(10 , "Junior Administrator");
        userlevels.put(30 , "Administrator");
        userlevels.put(50 , "Senior Administrator");
        userlevels.put(75 , "Assistant Head Administrator");
        userlevels.put(100, "Head Administrator");           
    }
    
    public static String[] loadAdminList()
    {
    	try{
    		admins = Config.ADMIN_LIST_DIR.list();
    	} catch (Exception e) { System.out.println("Error getting admin list."); }
    	return admins;
    }
}
